developmentor - a developer services company				  
				      Essential .NET Security
   Modules

CAS Enforcement


1. The stackwalk
was instituted to reduce performance until version 2.0 comes out
always happens, no matter what type of demand is in use
helps stop malware from luring a trusted component to do evil deeds

2. SuppressUnmanagedCodeSecurity
should be used whenever calling native code to increase performance
should be used cautiously when implementing secure gateways to native code
turns a stack walking demand (for the right to call unmanaged code) into a link time demand for that same permission
a and c
b and c
all of the above

3. Assert
can halt the stackwalk only if the assembly performing the assertion has two permissions: the permission to Assert and the permission being asserted
allows you to test whether your caller has a permission that you specify
is something you should sprinkle liberally throughout your code to help simplify security

4. The difference between the Everything permission set and FullTrust is
trivial and can be ignored
that being granted Everything results in a partially trusted assembly, while being granted FullTrust leads to, well, full trust, which is subtly different!
only assemblies granted Everything can call other strongly named assemblies

5. You should mark your assembly with AllowPartiallyTrustedCallers
only after a careful security audit to determine that the assembly is safe for use by mobile code (which, depending on the policy in place, could be malware downloaded from the Internet)
as the first step of building a strongly named assembly, to avoid security problems later on
unless you plan on strongly naming it
all of the above